import { ApiProperty } from '@nestjs/swagger';
import { IsString, IsNotEmpty } from 'class-validator';

export class CreateTagDto {
  @ApiProperty({ example: '前端开发', description: '标签名称' })
  @IsNotEmpty({ message: '标签名称不能为空！' })
  @IsString()
  name: string;

  @ApiProperty({ example: '', description: '标签链接' })
  @IsString()
  slug: string;

  @ApiProperty({ example: '', description: '关键词' })
  @IsString()
  keywords: string;

  @ApiProperty({ example: '', description: '描述' })
  @IsString()
  description: string;
}
